/*
 * lab1.fx
 *
 * Created on 13.09.2009, 17:52:09
 */

package javafx179labs.dergunov.lab1;

/**
 * @author Владелец
 */
//Фдисятке, хочется придраться, но не получается.
import javafx.stage.Stage;
import javafx.scene.Scene;
import javafx.scene.text.Text;
import javafx.scene.text.Font;
import javafx.scene.paint.Color;
//import javafx.scene.effect.Bloom; //Не стесняйтесь, удаляйте.
import javafx.scene.*;
import javafx.scene.shape.*;
import javafx.scene.text.*;
import javafx.scene.paint.*;
import javafx.scene.effect.*;
import javafx.scene.effect.light.*;
import javafx.scene.transform.*;


/**
 * @author Владелец
 */

Stage {
    title: "Desu~"
    width: 750
    height: 550
    scene: Scene {
      content: [

       Group {
           content: [
          // object bounding box relative (proportional:true, default)
        Rectangle {
             x: 0 y: 0 width: 750 height: 550
             //transforms: Shear { x: -0.35 y: 0 }
             fill: LinearGradient {
             startX: 0.0, startY: 0.0, endX: 1.0, endY: 0.0
             proportional: true
             stops: [ Stop { offset: 0.3 color: Color.BLUE },
                     Stop { offset: 1.0 color: Color.BLACK } ]
                  }
                },

              ]
            }

        Rectangle {
              transforms: Rotate { angle: -3 }
              x: 14, y: 14
              width: 640, height: 480
              fill: Color.LIGHTGRAY
              },

        Rectangle {
              transforms: Rotate { angle: -3 }
              x: 7, y: 7
              width: 640, height: 480
              fill: Color.GRAY
              },

        Rectangle {
              transforms: Rotate { angle: -3 }
              x: 0, y: 0
              width: 640, height: 480
              fill: Color.BLACK
              },

        Ellipse {
              effect: GaussianBlur {}
              cache: true
              transforms: Rotate { angle: -8 }
              centerX: 195, centerY: 150
              radiusX: 150, radiusY: 80
              fill: Color.ORANGE
              },



        Ellipse {
              effect: MotionBlur { radius: 10 angle: -30 }
              centerX: 120, centerY: 120
              radiusX: 40, radiusY: 30
              fill: Color.WHITE
            }

        Circle {
               effect: Lighting {
                light: DistantLight { azimuth: -25 }
                surfaceScale: 2
                }
              centerX: 120, centerY: 120
              radius: 30
              fill: Color.GREEN
            },

        Ellipse {
                effect: Lighting {
                light: DistantLight { azimuth: -25 }
                surfaceScale: 2
                }
              centerX: 300, centerY: 110
              radiusX: 40, radiusY: 30
              fill: Color.WHITE
            }

        Circle {
              effect: MotionBlur { radius: 10 angle: -30 }
              centerX: 300, centerY: 110
              radius: 30
              fill: Color.RED
            },

        Ellipse {
              effect: GaussianBlur {}
              cache: true
              centerX: 130, centerY: 125
              radiusX: 3, radiusY: 8
              fill: Color.WHITE
            }



        Line {
                effect: GaussianBlur {}
              cache: true
              transforms: Rotate { angle: -2 }
              startX: 150, startY: 180
              endX: 250, endY: 175
              strokeWidth: 2
              stroke: Color.RED
            },

        Line {
               effect: GaussianBlur {}
              cache: true
              transforms: Rotate { angle: -2 }
              startX: 120, startY: 80
              endX: 160, endY: 95
              strokeWidth: 2
              stroke: Color.BLACK
            },

        Line {
              effect: GaussianBlur {}
              cache: true
              transforms: Rotate { angle: -2 }
              startX: 315, startY: 67
              endX: 265, endY: 82
              strokeWidth: 2
              stroke: Color.BLACK
            },

         Circle {
              effect: Lighting {
                light: DistantLight { azimuth: 25 }
                surfaceScale: 3
                }
              centerX: 105, centerY: 105
              radius: 5
              fill: Color.WHITE
            }

         Circle {
              effect: Lighting {
                light: DistantLight { azimuth: 25 }
                surfaceScale: 3
                }
              centerX: 310, centerY: 90
              radius: 5
              fill: Color.WHITE
            }

         Text {
               font : Font {
               size : 30
                }
               fill: Color.WHITE
               effect: Reflection { fraction: 0.7 }
               cache: true
               x: 180
               y: 320
               transforms: Shear { x: -0.35 y: 0 }
               content: "Yes, I can't paint desu~"
            },

        ]
    }
}
